package com.atguigu.lease.common.exception;

import com.atguigu.lease.common.result.ResultCodeEnum;
import lombok.Data;

/**
 * projectName: lease
 *
 * @author: 王玉乾
 * time: 2024/10/8 2:33 周二
 * description:
 */
@Data
public class LeaseException extends RuntimeException{

    private ResultCodeEnum resultCodeEnum;

    public LeaseException(String message) {
        super(message);
    }

    public LeaseException(ResultCodeEnum resultCodeEnum) {
        super(resultCodeEnum.getMessage());
        this.resultCodeEnum=resultCodeEnum;
    }

}